<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.14"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>libslic3r: src/libslic3r/Fill/FillGyroid.hpp Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="Slic3r_192px_transparent.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">libslic3r
   </div>
   <div id="projectbrief">Library for generating gcode from 3d models</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.14 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_f69e6fbaea45487e96bc9ed8ccf9ff8f.html">libslic3r</a></li><li class="navelem"><a class="el" href="dir_10c1722f8d09bb92760dc3ef99d9d247.html">Fill</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">FillGyroid.hpp</div>  </div>
</div><!--header-->
<div class="contents">
<a href="_fill_gyroid_8hpp.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="preprocessor">#ifndef slic3r_FillGyroid_hpp_</span></div><div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="preprocessor">#define slic3r_FillGyroid_hpp_</span></div><div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;</div><div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="preprocessor">#include &lt;map&gt;</span></div><div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;</div><div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="preprocessor">#include &quot;../libslic3r.h&quot;</span></div><div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;</div><div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="_fill_8hpp.html">Fill.hpp</a>&quot;</span></div><div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;</div><div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="keyword">namespace </span><a class="code" href="namespace_slic3r.html">Slic3r</a> {</div><div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;</div><div class="line"><a name="l00012"></a><span class="lineno"><a class="line" href="class_slic3r_1_1_fill_gyroid.html">   12</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_slic3r_1_1_fill_gyroid.html">FillGyroid</a> : <span class="keyword">public</span> <a class="code" href="class_slic3r_1_1_fill.html">Fill</a></div><div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;{</div><div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<span class="keyword">public</span>:</div><div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;</div><div class="line"><a name="l00016"></a><span class="lineno"><a class="line" href="class_slic3r_1_1_fill_gyroid.html#adc507bd941e1f275d74b3247e76a2528">   16</a></span>&#160;    <a class="code" href="class_slic3r_1_1_fill_gyroid.html#adc507bd941e1f275d74b3247e76a2528">FillGyroid</a>(){ <a class="code" href="class_slic3r_1_1_fill_gyroid.html#a1d00d19c63c548414fd499b0ff22f018">scaling</a> = 1.75; }</div><div class="line"><a name="l00017"></a><span class="lineno"><a class="line" href="class_slic3r_1_1_fill_gyroid.html#aa5abf6ab587c957d92890b2ce24d8413">   17</a></span>&#160;    <span class="keyword">virtual</span> <a class="code" href="class_slic3r_1_1_fill.html">Fill</a>* <a class="code" href="class_slic3r_1_1_fill_gyroid.html#aa5abf6ab587c957d92890b2ce24d8413">clone</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <span class="keyword">new</span> <a class="code" href="class_slic3r_1_1_fill_gyroid.html#adc507bd941e1f275d74b3247e76a2528">FillGyroid</a>(*<span class="keyword">this</span>); };</div><div class="line"><a name="l00018"></a><span class="lineno"><a class="line" href="class_slic3r_1_1_fill_gyroid.html#a2c997f492aad3d469d69cda19a4ea763">   18</a></span>&#160;    <span class="keyword">virtual</span> <a class="code" href="class_slic3r_1_1_fill_gyroid.html#a2c997f492aad3d469d69cda19a4ea763">~FillGyroid</a>() {}</div><div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;</div><div class="line"><a name="l00021"></a><span class="lineno"><a class="line" href="class_slic3r_1_1_fill_gyroid.html#a2bfacc92840ffdb911ac5e710b9ead2f">   21</a></span>&#160;    <span class="keyword">virtual</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_fill_gyroid.html#a2bfacc92840ffdb911ac5e710b9ead2f">use_bridge_flow</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <span class="keyword">true</span>; }</div><div class="line"><a name="l00022"></a><span class="lineno">   22</span>&#160;</div><div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;<span class="keyword">protected</span>:</div><div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;    </div><div class="line"><a name="l00026"></a><span class="lineno"><a class="line" href="class_slic3r_1_1_fill_gyroid.html#a1d00d19c63c548414fd499b0ff22f018">   26</a></span>&#160;    <span class="keywordtype">float</span> <a class="code" href="class_slic3r_1_1_fill_gyroid.html#a1d00d19c63c548414fd499b0ff22f018">scaling</a>;</div><div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160;</div><div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160;</div><div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160;    <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="class_slic3r_1_1_fill_gyroid.html#ad2786a4fc502d7fd07a0fef2f1bc2a48">_fill_surface_single</a>( </div><div class="line"><a name="l00030"></a><span class="lineno">   30</span>&#160;        <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span>                     thickness_layers,</div><div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;        <span class="keyword">const</span> std::pair&lt;float, Point&gt;   &amp;direction, </div><div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;        <a class="code" href="class_slic3r_1_1_ex_polygon.html">ExPolygon</a>                       &amp;expolygon, </div><div class="line"><a name="l00033"></a><span class="lineno">   33</span>&#160;        <a class="code" href="namespace_slic3r.html#a498065f79ccb865fc410d4afeacffc9c">Polylines</a>                       *polylines_out);</div><div class="line"><a name="l00034"></a><span class="lineno">   34</span>&#160;    </div><div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;    <a class="code" href="namespace_slic3r.html#a498065f79ccb865fc410d4afeacffc9c">Polylines</a> <a class="code" href="class_slic3r_1_1_fill_gyroid.html#af3d6e9928b8304ee9babe3c99c1f30dd">makeGrid</a>(<a class="code" href="namespace_slic3r.html#ab6d77625bc973b0c03e577944f90f297">coord_t</a> gridZ, <span class="keywordtype">double</span> <a class="code" href="class_slic3r_1_1_fill.html#ad7c1a26cf2aca99c48a0aaa4ad725ee3">density</a>, <span class="keywordtype">double</span> layer_width, <span class="keywordtype">size_t</span> gridWidth, <span class="keywordtype">size_t</span> gridHeight, <span class="keywordtype">size_t</span> curveType);</div><div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;    <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_slic3r_1_1_fill_gyroid.html#aca7eedc4ad5c3f356d47a5529c3d82b3">correctOrderAndAdd</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> num, <a class="code" href="class_slic3r_1_1_polyline.html">Polyline</a> poly, <a class="code" href="namespace_slic3r.html#a498065f79ccb865fc410d4afeacffc9c">Polylines</a> &amp;array);</div><div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;    <a class="code" href="class_slic3r_1_1_polyline.html">Polyline</a> <a class="code" href="class_slic3r_1_1_fill_gyroid.html#aee3c573b475dc172e4b2d8c00d20aa64">makeLineHori</a>(<span class="keywordtype">double</span> xPos, <span class="keywordtype">double</span> yPos, <span class="keywordtype">double</span> width, <span class="keywordtype">double</span> height, </div><div class="line"><a name="l00041"></a><span class="lineno">   41</span>&#160;        <span class="keywordtype">double</span> currentYBegin, <span class="keywordtype">double</span> segmentSize, <a class="code" href="namespace_slic3r.html#ab6d77625bc973b0c03e577944f90f297">coord_t</a> scaleFactor, </div><div class="line"><a name="l00042"></a><span class="lineno">   42</span>&#160;        <span class="keywordtype">double</span> zCs, <span class="keywordtype">double</span> zSn, </div><div class="line"><a name="l00043"></a><span class="lineno">   43</span>&#160;        <span class="keywordtype">bool</span> flip, <span class="keywordtype">double</span> decal=0);</div><div class="line"><a name="l00045"></a><span class="lineno">   45</span>&#160;    <a class="code" href="class_slic3r_1_1_polyline.html">Polyline</a> <a class="code" href="class_slic3r_1_1_fill_gyroid.html#a1406bd41e488a9df60c705a596f1651b">makeLineVert</a>(<span class="keywordtype">double</span> xPos, <span class="keywordtype">double</span> yPos, <span class="keywordtype">double</span> width, <span class="keywordtype">double</span> height, </div><div class="line"><a name="l00046"></a><span class="lineno">   46</span>&#160;        <span class="keywordtype">double</span> currentXBegin, <span class="keywordtype">double</span> segmentSize, <a class="code" href="namespace_slic3r.html#ab6d77625bc973b0c03e577944f90f297">coord_t</a> scaleFactor, </div><div class="line"><a name="l00047"></a><span class="lineno">   47</span>&#160;        <span class="keywordtype">double</span> zCs, <span class="keywordtype">double</span> zSn, </div><div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160;        <span class="keywordtype">bool</span> flip, <span class="keywordtype">double</span> decal=0);</div><div class="line"><a name="l00049"></a><span class="lineno">   49</span>&#160;</div><div class="line"><a name="l00050"></a><span class="lineno">   50</span>&#160;};</div><div class="line"><a name="l00051"></a><span class="lineno">   51</span>&#160;</div><div class="line"><a name="l00052"></a><span class="lineno">   52</span>&#160;} <span class="comment">// namespace Slic3r</span></div><div class="line"><a name="l00053"></a><span class="lineno">   53</span>&#160;</div><div class="line"><a name="l00054"></a><span class="lineno">   54</span>&#160;<span class="preprocessor">#endif // slic3r_FillGyroid_hpp_</span></div><div class="ttc" id="class_slic3r_1_1_fill_gyroid_html_a1d00d19c63c548414fd499b0ff22f018"><div class="ttname"><a href="class_slic3r_1_1_fill_gyroid.html#a1d00d19c63c548414fd499b0ff22f018">Slic3r::FillGyroid::scaling</a></div><div class="ttdeci">float scaling</div><div class="ttdoc">mult of density, to have a good of weight for each density parameter </div><div class="ttdef"><b>Definition:</b> FillGyroid.hpp:26</div></div>
<div class="ttc" id="class_slic3r_1_1_fill_gyroid_html_ad2786a4fc502d7fd07a0fef2f1bc2a48"><div class="ttname"><a href="class_slic3r_1_1_fill_gyroid.html#ad2786a4fc502d7fd07a0fef2f1bc2a48">Slic3r::FillGyroid::_fill_surface_single</a></div><div class="ttdeci">virtual void _fill_surface_single(unsigned int thickness_layers, const std::pair&lt; float, Point &gt; &amp;direction, ExPolygon &amp;expolygon, Polylines *polylines_out)</div><div class="ttdef"><b>Definition:</b> FillGyroid.cpp:158</div></div>
<div class="ttc" id="class_slic3r_1_1_fill_gyroid_html_aee3c573b475dc172e4b2d8c00d20aa64"><div class="ttname"><a href="class_slic3r_1_1_fill_gyroid.html#aee3c573b475dc172e4b2d8c00d20aa64">Slic3r::FillGyroid::makeLineHori</a></div><div class="ttdeci">Polyline makeLineHori(double xPos, double yPos, double width, double height, double currentYBegin, double segmentSize, coord_t scaleFactor, double zCs, double zSn, bool flip, double decal=0)</div><div class="ttdoc">create a curved horinzontal line (for each x, compute y) </div><div class="ttdef"><b>Definition:</b> FillGyroid.cpp:36</div></div>
<div class="ttc" id="class_slic3r_1_1_polyline_html"><div class="ttname"><a href="class_slic3r_1_1_polyline.html">Slic3r::Polyline</a></div><div class="ttdef"><b>Definition:</b> Polyline.hpp:18</div></div>
<div class="ttc" id="class_slic3r_1_1_fill_gyroid_html"><div class="ttname"><a href="class_slic3r_1_1_fill_gyroid.html">Slic3r::FillGyroid</a></div><div class="ttdef"><b>Definition:</b> FillGyroid.hpp:12</div></div>
<div class="ttc" id="namespace_slic3r_html_ab6d77625bc973b0c03e577944f90f297"><div class="ttname"><a href="namespace_slic3r.html#ab6d77625bc973b0c03e577944f90f297">Slic3r::coord_t</a></div><div class="ttdeci">long coord_t</div><div class="ttdef"><b>Definition:</b> libslic3r.h:41</div></div>
<div class="ttc" id="class_slic3r_1_1_fill_gyroid_html_af3d6e9928b8304ee9babe3c99c1f30dd"><div class="ttname"><a href="class_slic3r_1_1_fill_gyroid.html#af3d6e9928b8304ee9babe3c99c1f30dd">Slic3r::FillGyroid::makeGrid</a></div><div class="ttdeci">Polylines makeGrid(coord_t gridZ, double density, double layer_width, size_t gridWidth, size_t gridHeight, size_t curveType)</div><div class="ttdoc">create the gyroid grid to clip. </div><div class="ttdef"><b>Definition:</b> FillGyroid.cpp:71</div></div>
<div class="ttc" id="class_slic3r_1_1_fill_gyroid_html_adc507bd941e1f275d74b3247e76a2528"><div class="ttname"><a href="class_slic3r_1_1_fill_gyroid.html#adc507bd941e1f275d74b3247e76a2528">Slic3r::FillGyroid::FillGyroid</a></div><div class="ttdeci">FillGyroid()</div><div class="ttdef"><b>Definition:</b> FillGyroid.hpp:16</div></div>
<div class="ttc" id="class_slic3r_1_1_fill_html_ad7c1a26cf2aca99c48a0aaa4ad725ee3"><div class="ttname"><a href="class_slic3r_1_1_fill.html#ad7c1a26cf2aca99c48a0aaa4ad725ee3">Slic3r::Fill::density</a></div><div class="ttdeci">float density</div><div class="ttdef"><b>Definition:</b> Fill.hpp:51</div></div>
<div class="ttc" id="class_slic3r_1_1_fill_gyroid_html_a2c997f492aad3d469d69cda19a4ea763"><div class="ttname"><a href="class_slic3r_1_1_fill_gyroid.html#a2c997f492aad3d469d69cda19a4ea763">Slic3r::FillGyroid::~FillGyroid</a></div><div class="ttdeci">virtual ~FillGyroid()</div><div class="ttdef"><b>Definition:</b> FillGyroid.hpp:18</div></div>
<div class="ttc" id="class_slic3r_1_1_fill_gyroid_html_aca7eedc4ad5c3f356d47a5529c3d82b3"><div class="ttname"><a href="class_slic3r_1_1_fill_gyroid.html#aca7eedc4ad5c3f356d47a5529c3d82b3">Slic3r::FillGyroid::correctOrderAndAdd</a></div><div class="ttdeci">void correctOrderAndAdd(const int num, Polyline poly, Polylines &amp;array)</div><div class="ttdoc">add line poly in reverse if needed into array </div><div class="ttdef"><b>Definition:</b> FillGyroid.cpp:60</div></div>
<div class="ttc" id="class_slic3r_1_1_fill_gyroid_html_a1406bd41e488a9df60c705a596f1651b"><div class="ttname"><a href="class_slic3r_1_1_fill_gyroid.html#a1406bd41e488a9df60c705a596f1651b">Slic3r::FillGyroid::makeLineVert</a></div><div class="ttdeci">Polyline makeLineVert(double xPos, double yPos, double width, double height, double currentXBegin, double segmentSize, coord_t scaleFactor, double zCs, double zSn, bool flip, double decal=0)</div><div class="ttdoc">create a curved vertival line (for each y, compute x) </div><div class="ttdef"><b>Definition:</b> FillGyroid.cpp:12</div></div>
<div class="ttc" id="class_slic3r_1_1_fill_gyroid_html_a2bfacc92840ffdb911ac5e710b9ead2f"><div class="ttname"><a href="class_slic3r_1_1_fill_gyroid.html#a2bfacc92840ffdb911ac5e710b9ead2f">Slic3r::FillGyroid::use_bridge_flow</a></div><div class="ttdeci">virtual bool use_bridge_flow() const</div><div class="ttdoc">require bridge flow since most of this pattern hangs in air </div><div class="ttdef"><b>Definition:</b> FillGyroid.hpp:21</div></div>
<div class="ttc" id="namespace_slic3r_html"><div class="ttname"><a href="namespace_slic3r.html">Slic3r</a></div><div class="ttdef"><b>Definition:</b> BoundingBox.cpp:4</div></div>
<div class="ttc" id="class_slic3r_1_1_ex_polygon_html"><div class="ttname"><a href="class_slic3r_1_1_ex_polygon.html">Slic3r::ExPolygon</a></div><div class="ttdef"><b>Definition:</b> ExPolygon.hpp:16</div></div>
<div class="ttc" id="class_slic3r_1_1_fill_gyroid_html_aa5abf6ab587c957d92890b2ce24d8413"><div class="ttname"><a href="class_slic3r_1_1_fill_gyroid.html#aa5abf6ab587c957d92890b2ce24d8413">Slic3r::FillGyroid::clone</a></div><div class="ttdeci">virtual Fill * clone() const</div><div class="ttdef"><b>Definition:</b> FillGyroid.hpp:17</div></div>
<div class="ttc" id="_fill_8hpp_html"><div class="ttname"><a href="_fill_8hpp.html">Fill.hpp</a></div></div>
<div class="ttc" id="namespace_slic3r_html_a498065f79ccb865fc410d4afeacffc9c"><div class="ttname"><a href="namespace_slic3r.html#a498065f79ccb865fc410d4afeacffc9c">Slic3r::Polylines</a></div><div class="ttdeci">std::vector&lt; Polyline &gt; Polylines</div><div class="ttdef"><b>Definition:</b> Polyline.hpp:14</div></div>
<div class="ttc" id="class_slic3r_1_1_fill_html"><div class="ttname"><a href="class_slic3r_1_1_fill.html">Slic3r::Fill</a></div><div class="ttdef"><b>Definition:</b> Fill.hpp:20</div></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.14
</small></address>
</body>
</html>
